import { Spin } from 'antd';
import styled from 'styled-components'
const Wrapper = styled.div`
width: 100vw;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
`;
const ParentWrapper = styled.div`
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
`;
export function CircleLoading({ target }) {
  if (target === 'parent') {
    return (
      <ParentWrapper>
        <Spin size="large" />
      </ParentWrapper>
    );
  }

  return (
    <Wrapper>
      <Spin size="large" />
    </Wrapper>
  );
}
